import 'package:flutter/material.dart';
import 'package:practise/ui/colors.dart';

class BottomTab extends StatelessWidget {

  @override
  Widget build(BuildContext context) {
    return Container(
      padding: EdgeInsets.only(top: 10, bottom: 10),
      color: ProjectColors.PAGE_DARK,
      child: Row(
        mainAxisAlignment: MainAxisAlignment.spaceAround,
        children: [
          _getTab('发现', Icons.music_note, true),
          _getTab('博客', Icons.wifi_tethering_sharp, false),
          _getTab('我的', Icons.queue_music, false),
          _getTab('K歌', Icons.cast, false),
          _getTab('发现', Icons.people, false),
        ],
      ),
    );
  }

  Widget _getTab(title, icon, bool selected) {
    return Column(
      children: [
        Icon(icon, size: 20, color: Colors.white,),
        Padding(padding: EdgeInsets.only(top: 5)),
        Text(
          title,
          style: TextStyle(color: selected ? Colors.red : Colors.white, fontSize: 10),
        )
      ],
    );
  }
}
